package day07;

import day03.Ifelse;

import java.util.Scanner;

public class Guessing {
    public static void main(String[] args) {
        Scanner scan=new Scanner(System.in);
        int num=(int)(Math.random()*500+1);
        while(true){
            System.out.println("猜");
            int guess= scan.nextInt();
            System.out.println(num);
            if (guess>num){
                System.out.println("大");

                }
            else if(guess<num){
                System.out.println("小");

            }
             else {
                System.out.println("对了");
                break;
            }
        }
    }
}
